var shoubound = false;
function h() {
	$("#tips_rooms").hide();
}
//提示框
function t(obj,type,id) {
	var s = "";
	if(type == "v1") {
		$("#tips_rooms").width("300");
		s = $("#"+id+"_v1").html();
	} else if(type == "v2") {  //价格排期
		$("#tips_rooms").width(42*7+10);
		s = $("#"+id+"_v2").html();
	} else if(type == "v3") {
		$("#tips_rooms").width("300");
		s = $("#"+id+"_v3").html();
	}
	var offset = $(obj).offset();
	$("#tips_rooms").css({left:(offset.left-$("#tips_rooms").width()/2)+$(obj).width()/2,top:offset.top+20});
	$("#tips_rooms .room").html(s);
	$("#tips_rooms").show();
}
$(function(){
   $('#tm3').click(function(){showCalendar('tm3','tm4','chgdate')});
   $('#tm4').click(function(){showCalendar('tm4','','chgdate');});
});

function chgdate() {
	var tm3 = $("#tm3").val();
	var tm4 = $("#tm4").val();
	$.get(siteurl+"index.php",{ac:"hotel",at:"changedate",tm1:tm3,tm2:tm4,ran:Math.random()},
	function(data){}); 
	window.location.reload();
}